<#import "../user_defined_function.ftl" as self_defined>
package ${cfg.package_name}.bean;


import com.baomidou.mybatisplus.annotation.*;
import lombok.*;
import com.rt.easyjava.common.base.BaseV3Bean;
import java.util.Date;
import java.math.BigDecimal;
import java.io.Serializable;

/**
 * ${table.comment!}
 * @author ${author}
 * @since ${date}
 */
@Data
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = true)
@TableName(value = "${table.name}")
public class ${entity} extends BaseV3Bean<${entity}>{

<#list table.fields as field>
    <#if self_defined.isIgnProp(field.propertyName)==true>
        <#continue>
    </#if>

    <#if field.keyFlag>
        <#assign keyPropertyName="${field.propertyName}"/>
    </#if>
    <#if field.keyFlag>
    <#-- 主键 -->
    /**
     * 主键 : ${field.name}  ${field.comment!}
     */
    @TableId(value = "${field.name}", type = IdType.AUTO)
    <#-- 普通字段 -->
    <#elseif !field.keyFlag>
    /**
     * ${field.name}: ${field.comment!}
     */
    </#if>
    <#-- 乐观锁注解 -->
    <#if (versionFieldName!"") == field.name>
    @Version
    </#if>
    <#-- 逻辑删除注解 -->
    <#if (logicDeleteFieldName!"") == field.name>
    @TableLogic
    </#if>
    <#if field.propertyType == "LocalDateTime">
    private Date ${field.propertyName};
    </#if>
    <#if field.propertyType != "LocalDateTime">
    private ${field.propertyType} ${field.propertyName};
    </#if>
</#list>

    /*
    @Override
    public Serializable pkVal() {
        return this.id;
    }
    */


}
